'use strict';
/**
 * Created by FreezeSoul on 2015/9/30.
 */
define([
        'angular',
        'app/modules/page/define',
        'app/modules/page/services/page'
    ],
    function(angular) {
        angular.module('ad.page')
            .controller('adPageDeleteController',['$scope','$uibModalInstance','adPageEditService','items'
                ,function($scope,$uibModalInstance,service,items) {
                    $scope.items = items;

                    $scope.ok = function () {
                        service.removePages($scope.items).then(function(data){
                            $uibModalInstance.close(data);
                        });
                    };

                    $scope.cancel = function () {
                        $uibModalInstance.dismiss('cancel');
                    };
            }]);
    });